import fetch from '@/utils/fetch'

export function getCateList(query) {
  return fetch({
    url: '/api/category/list',
    method: 'post',
    data: query
  })
}

export function createCateList(query) {
  return fetch({
    url: '/api/category',
    method: 'post',
    data: query
  })
}
export function deleteCateList(id) {
  return fetch({
    url: `/api/category/delete/${id}`,
    method: 'delete'
  })
}

export function editCateList(query) {
  return fetch({
    url: '/api/category/update',
    method: 'put',
    data: query
  })
}
